package com.ruoyi.city.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.city.mapper.SchoolMapper;
import com.ruoyi.city.domain.School;
import com.ruoyi.city.service.ISchoolService;

/**
 * 学校信息Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-09-10
 */
@Service
public class SchoolServiceImpl implements ISchoolService 
{
    @Autowired
    private SchoolMapper schoolMapper;

    /**
     * 查询学校信息
     * 
     * @param schoolId 学校信息主键
     * @return 学校信息
     */
    @Override
    public School selectSchoolBySchoolId(Long schoolId)
    {
        return schoolMapper.selectSchoolBySchoolId(schoolId);
    }

    /**
     * 查询学校信息列表
     * 
     * @param school 学校信息
     * @return 学校信息
     */
    @Override
    public List<School> selectSchoolList(School school)
    {
        return schoolMapper.selectSchoolList(school);
    }

    /**
     * 新增学校信息
     * 
     * @param school 学校信息
     * @return 结果
     */
    @Override
    public int insertSchool(School school)
    {
        return schoolMapper.insertSchool(school);
    }

    /**
     * 修改学校信息
     * 
     * @param school 学校信息
     * @return 结果
     */
    @Override
    public int updateSchool(School school)
    {
        return schoolMapper.updateSchool(school);
    }

    /**
     * 批量删除学校信息
     * 
     * @param schoolIds 需要删除的学校信息主键
     * @return 结果
     */
    @Override
    public int deleteSchoolBySchoolIds(Long[] schoolIds)
    {
        return schoolMapper.deleteSchoolBySchoolIds(schoolIds);
    }

    /**
     * 删除学校信息信息
     * 
     * @param schoolId 学校信息主键
     * @return 结果
     */
    @Override
    public int deleteSchoolBySchoolId(Long schoolId)
    {
        return schoolMapper.deleteSchoolBySchoolId(schoolId);
    }
}
